package com.data.center.entity.neo4j;
import lombok.Data;
import org.springframework.data.annotation.Id;
import org.springframework.data.neo4j.core.schema.*;
import org.springframework.data.neo4j.core.schema.Property;

import java.time.LocalDateTime;
import java.util.List;

@Data
@Node
public class neoOrganization {

        @Id
        @Property(name = "organization_id") // 显式指定主键字段名
        private String organizationId;

        @Property(name = "name") // 显式指定字段名
        private String name;

        @Property(name = "abbreviation") // 显式指定字段名
        private List<String> abbreviation; // 多值字段

        @Property(name = "category") // 显式指定字段名
        private String category;

        @Property(name = "uscc") // 显式指定字段名
        private String uscc;

        @Property(name = "representative") // 显式指定字段名
        private String representative;

        @Property(name = "description") // 显式指定字段名
        private String description;

        @Property(name = "country") // 显式指定字段名
        private String country;

        @Property(name = "division_code") // 显式指定字段名
        private String divisionCode;

        @Property(name = "address") // 显式指定字段名
        private String address;

        @Property(name = "post_code") // 显式指定字段名
        private String postCode;

        @Property(name = "status") // 显式指定字段名
        private Integer status;

        @Property(name = "approver") // 显式指定字段名
        private String approver;
        @Relationship(type = "APPROVED_BY", direction = Relationship.Direction.OUTGOING)
        private Approver approverEntity;

        @Property(name = "approval_time") // 显式指定字段名
        private LocalDateTime approvalTime;

        public neoOrganization() {
        }


}
